package com.damuzee.system.system.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.mybatis.sql.page.Page;
import org.springframework.stereotype.Service;

import com.damuzee.system.system.domain.PermOrg;
import com.damuzee.system.system.persistence.PermOrgMapper;
import com.damuzee.system.system.service.PermOrgService;

@Service
public class  PermOrgServiceImpl implements  PermOrgService {

	public Page< PermOrg> getPermOrgList(Page<  PermOrg> page,   PermOrg  bean) {
		return mapper.selectChildList(page,   bean.getOrgId());
	}

	public void savePermOrg( PermOrg bean) {
		 
		mapper.insert(bean);
	}
	
 
	public List<PermOrg> getPermOrgList( PermOrg bean) {
		 
		return mapper.selectList(bean);
	}

	 
	public void updatePermOrg( PermOrg bean) {
		mapper.update(bean); 
	}

 
	public List<PermOrg> getChildList(Long id) {
		return mapper.selectChildList(id);
	}



	@Resource
	private  PermOrgMapper mapper ;
}
